package com.ruoyi.process.controller;

import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.process.service.IFlowDefine;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 流程定义
 *此类实现钉钉中的json转xml,xml进行部署
 * @author wuenguo
 * @date 2022-01-04
 */
@RestController
@RequestMapping("/workflow/flowdefine")
public class FlowDefineController {
    @Autowired
    private IFlowDefine flowDefine;
    /**
     * 发布模型,pfid目前暂时先不用，等json部分搞好后，再使用
     */
    @GetMapping("/deployed")
    public AjaxResult deployed(Long pfid) {
        flowDefine.deployfile(pfid);
        return AjaxResult.success();
    }


}
